package com.feige.pojo.vo;


import com.feige.pojo.Permission;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.util.Date;
import java.util.List;


@ApiModel(value="PermissionVo对象")
public class PermissionVo {

    @ApiModelProperty(value = "ID")
    private Long id;

    @ApiModelProperty(value = "父ID,所属上级")
    private Long pid;

    @ApiModelProperty(value = "类型(1:目录,2:菜单,3:按钮)")
    private Integer type;

    @ApiModelProperty(value = "名称")
    private String name;

    @ApiModelProperty(value = "权限值")
    private String permissionValue;

    @ApiModelProperty(value = "访问路径")
    private String path;

    @ApiModelProperty(value = "组件路径")
    private String component;

    @ApiModelProperty(value = "图标")
    private String icon;

    @ApiModelProperty(value = "状态（0表示禁用，1表示可用）")
    private Integer status;

    @ApiModelProperty(value = "下级")
    private List<Permission> children;

    @ApiModelProperty(value = "创建时间")
    private Date gmtCreate;

    public PermissionVo() {
    }

    public PermissionVo(Long id, Long pid, Integer type, String name, String permissionValue, String path, String component, String icon, Integer status, List<Permission> children, Date gmtCreate) {
        this.id = id;
        this.pid = pid;
        this.type = type;
        this.name = name;
        this.permissionValue = permissionValue;
        this.path = path;
        this.component = component;
        this.icon = icon;
        this.status = status;
        this.children = children;
        this.gmtCreate = gmtCreate;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getPid() {
        return pid;
    }

    public void setPid(Long pid) {
        this.pid = pid;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPermissionValue() {
        return permissionValue;
    }

    public void setPermissionValue(String permissionValue) {
        this.permissionValue = permissionValue;
    }

    public String getPath() {
        return path;
    }

    public void setPath(String path) {
        this.path = path;
    }

    public String getComponent() {
        return component;
    }

    public void setComponent(String component) {
        this.component = component;
    }

    public String getIcon() {
        return icon;
    }

    public void setIcon(String icon) {
        this.icon = icon;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public List<Permission> getChildren() {
        return children;
    }

    public void setChildren(List<Permission> children) {
        this.children = children;
    }

    public Date getGmtCreate() {
        return gmtCreate;
    }

    public void setGmtCreate(Date gmtCreate) {
        this.gmtCreate = gmtCreate;
    }

    @Override
    public String toString() {
        return "PermissionVo{" +
                "id=" + id +
                ", pid=" + pid +
                ", name='" + name + '\'' +
                ", permissionValue='" + permissionValue + '\'' +
                ", path='" + path + '\'' +
                ", component='" + component + '\'' +
                ", icon='" + icon + '\'' +
                ", status=" + status +
                ", children=" + children +
                ", gmtCreate=" + gmtCreate +
                '}';
    }
}
